package com.samphanie.dries.repository;

import com.samphanie.dries.domain.Role;
import com.samphanie.dries.domain.User;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import java.util.Optional;
import java.util.Set;

/**
 * @Description:
 * @Author ZSY
 * @createTime 2021/2/26 11:01
 */
@Repository
public interface RoleRepo extends JpaRepository<Role, Long> {

    Set<Role> findByAuthorityIn(Set<String> authority);

    Optional<Role> findOptionalByAuthority(String authority);
}
